Install the accessibility-dump tests
authorMatthias Clasen <mclasen@redhat.com>
Wed, 15 May 2013 03:16:56 +0000 (23:16 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Wed, 15 May 2013 03:21:18 +0000 (23:21 -0400)
tests/a11y/Makefile.am
tests/a11y/a11ytests.test.in [new file with mode: 0644]

index d7a54becfc0f37ca5ea046e6436be9c7b89114a5..42ff568f94c839156cb634b263f6cb4cdca0cd0d 100644 (file)
@@ -1,4 +1,5 @@
 include $(top_srcdir)/Makefile.decl
+NULL =
 
 check_PROGRAMS = $(TEST_PROGS)
 
@@ -44,7 +45,7 @@ TEST_PROGS += util
 
 noinst_PROGS = testfocus
 
-EXTRA_DIST += \
+testdata = \
        hello-world.ui hello-world.txt \
        mnemonic.ui mnemonic.txt \
        accessible-name.ui accessible-name.txt \
@@ -71,6 +72,28 @@ EXTRA_DIST += \
        scale-drawvalue.ui scale-drawvalue.txt \
        placeholder-text.ui placeholder-text.txt \
        menu.ui menu.txt \
-       combos.ui combos.txt
+       combos.ui combos.txt \
+       $(NULL)
+
+if BUILDOPT_INSTALL_TESTS
+insttestdir=$(pkglibexecdir)/installed-tests
+insttest_PROGRAMS = accessibility-dump
+
+a11ytestdir = $(insttestdir)/a11ytests
+a11ytest_DATA = $(testdata)
+
+substitutions = \
+       -e s,@pkglibexecdir\@,$(pkglibexecdir),g \
+       $(NULL)
+
+a11ytests.test: a11ytests.test.in Makefile
+       $(AM_V_GEN) sed $(substitutions) $< > $@.tmp && mv $@.tmp $@
+
+EXTRA_DIST += \
+       a11ytests.test.in
+
+testmetadir = $(datadir)/installed-tests/$(PACKAGE)
+testmeta_DATA = a11ytests.test
+endif
 
 -include $(top_srcdir)/git.mk
diff --git a/tests/a11y/a11ytests.test.in b/tests/a11y/a11ytests.test.in
new file mode 100644 (file)
index 0000000..e794dcf
--- /dev/null
@@ -0,0 +1,4 @@
+[Test]
+Exec=/bin/sh -c "@pkglibexecdir@/installed-tests/accessibility-dump --directory @pkglibexecdir@/installed-tests/a11ytests"
+Type=session
+